package com.wetao.lib_common.bean.response;

import com.wetao.lib_common.base.Base2Response;
import com.wetao.lib_common.utils.JsonUtils;

import java.io.Serializable;
import java.util.List;

/**
 * author: zhouyh
 * created on: 3/10/21 4:36 PM
 * description:批阅详情数据
 */

public class ExamDetailInfo extends Base2Response {


    /**
     * code : 0
     * msg : 成功
     * data : {"name":"金太阳单元卷-第二套 Unit 2 Healthy eating","chapterName":null,"materialName":null,"score":0,"totalScore":268,"questionList":[{"questionNo":1,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What does the woman want to plant in the backyard? <\/span><\/p>\",\"options\":[{\"value\":\"Flowers.   \"},{\"value\":\"Grass.   \"},{\"value\":\"Vegetables.\"}],\"answers\":[\"B\"]}","answers":["B"],"voiceComment":null},{"questionNo":2,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What would be the woman\u2019s advice?<\/span><\/p>\",\"options\":[{\"value\":\"Don\u2019t eat cold dishes.\"},{\"value\":\"Don\u2019t drink cold water at lunch.\"},{\"value\":\"Don\u2019t add ice when drinking water.\"}],\"answers\":[\"C\"]}","answers":["C"],"voiceComment":null},{"questionNo":3,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What will the woman do on Saturday? <\/span><\/p>\",\"options\":[{\"value\":\"Play a game.   \"},{\"value\":\"Go to a concert.   \"},{\"value\":\"Pick up her cousin.\"}],\"answers\":[\"A\"]}","answers":["A"],"voiceComment":null}]}
     */

    private DataBean data;

    public DataBean getData() {
        return data;
    }

    public static ExamDetailInfo objectFromData(String str) {

        return (JsonUtils.getmGson()).fromJson(str, ExamDetailInfo.class);
    }


    public static class DataBean implements Serializable {
        /**
         * name : 金太阳单元卷-第二套 Unit 2 Healthy eating
         * chapterName : null
         * materialName : null
         * score : 0
         * totalScore : 268
         * questionList : [{"questionNo":1,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What does the woman want to plant in the backyard? <\/span><\/p>\",\"options\":[{\"value\":\"Flowers.   \"},{\"value\":\"Grass.   \"},{\"value\":\"Vegetables.\"}],\"answers\":[\"B\"]}","answers":["B"],"voiceComment":null},{"questionNo":2,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What would be the woman\u2019s advice?<\/span><\/p>\",\"options\":[{\"value\":\"Don\u2019t eat cold dishes.\"},{\"value\":\"Don\u2019t drink cold water at lunch.\"},{\"value\":\"Don\u2019t add ice when drinking water.\"}],\"answers\":[\"C\"]}","answers":["C"],"voiceComment":null},{"questionNo":3,"myScore":0,"questionScore":4,"myAnswer":null,"questionContent":"{\"explain\":{\"value\":\"\"},\"question\":\"<p style=\\\"line-height:1.2;\\\"><span style=\\\"font-family: Times New Roman\\\">What will the woman do on Saturday? <\/span><\/p>\",\"options\":[{\"value\":\"Play a game.   \"},{\"value\":\"Go to a concert.   \"},{\"value\":\"Pick up her cousin.\"}],\"answers\":[\"A\"]}","answers":["A"],"voiceComment":null}]
         */

        private String name;
        private String chapterName;
        private String materialName;
        private Float score;
        private Integer totalScore;
        private List<QuestionListBean> questionList;


        public static DataBean objectFromData(String str) {

            return (JsonUtils.getmGson()).fromJson(str, DataBean.class);
        }


        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getChapterName() {
            return chapterName;
        }

        public void setChapterName(String chapterName) {
            this.chapterName = chapterName;
        }

        public String getMaterialName() {
            return materialName;
        }

        public void setMaterialName(String materialName) {
            this.materialName = materialName;
        }

        public Float getScore() {
            return score;
        }

        public void setScore(Float score) {
            this.score = score;
        }

        public Integer getTotalScore() {
            return totalScore;
        }

        public void setTotalScore(Integer totalScore) {
            this.totalScore = totalScore;
        }

        public List<QuestionListBean> getQuestionList() {
            return questionList;
        }

        public void setQuestionList(List<QuestionListBean> questionList) {
            this.questionList = questionList;
        }

        public static class QuestionListBean implements Serializable {
            /**
             * questionNo : 1
             * myScore : 0
             * questionScore : 4
             * myAnswer : null
             * questionContent : {"explain":{"value":""},"question":"<p style=\"line-height:1.2;\"><span style=\"font-family: Times New Roman\">What does the woman want to plant in the backyard? </span></p>","options":[{"value":"Flowers.   "},{"value":"Grass.   "},{"value":"Vegetables."}],"answers":["B"]}
             * answers : ["B"]
             * voiceComment : null
             * duration:null
             */

            private Integer questionNo;
            private Float myScore;
            private Integer questionScore;
            private String myAnswer;
            private String questionContent;
            private String voiceComment;
            private String duration;
            private List<String> answers;

            private int playState;    //0未播放  1播放  2 暂停
            private String playerTime;

            public static QuestionListBean objectFromData(String str) {

                return (JsonUtils.getmGson()).fromJson(str, QuestionListBean.class);
            }


            public int getPlayState() {
                return playState;
            }

            public void setPlayState(int playState) {
                this.playState = playState;
            }

            public String getPlayerTime() {
                return playerTime;
            }

            public void setPlayerTime(String playerTime) {
                this.playerTime = playerTime;
            }

            public String getDuration() {
                return duration;
            }

            public void setDuration(String duration) {
                this.duration = duration;
            }

            public Integer getQuestionNo() {
                return questionNo;
            }

            public void setQuestionNo(Integer questionNo) {
                this.questionNo = questionNo;
            }

            public Float getMyScore() {
                return myScore;
            }

            public void setMyScore(Float myScore) {
                this.myScore = myScore;
            }

            public Integer getQuestionScore() {
                return questionScore;
            }

            public void setQuestionScore(Integer questionScore) {
                this.questionScore = questionScore;
            }

            public String getMyAnswer() {
                return myAnswer;
            }

            public void setMyAnswer(String myAnswer) {
                this.myAnswer = myAnswer;
            }

            public String getQuestionContent() {
                return questionContent;
            }

            public void setQuestionContent(String questionContent) {
                this.questionContent = questionContent;
            }

            public String getVoiceComment() {
                return voiceComment;
            }

            public void setVoiceComment(String voiceComment) {
                this.voiceComment = voiceComment;
            }

            public List<String> getAnswers() {
                return answers;
            }

            public void setAnswers(List<String> answers) {
                this.answers = answers;
            }

        }
    }
}
